package com.shanpin.shebao.model.material.constant;

public enum SourceType {
	
	SYSTEM(1, "系统"),
	MANUAL(2, "人工");
	
	public static SourceType of(int num) {
		SourceType[] ss = SourceType.values();
		for(SourceType s : ss) {
			if(s.getNum() == num) {
				return s;
			}
		}
		return null;
	}
	
	private final int num;
	private final String name;
	private SourceType(int num, String name) {
		this.num = num;
		this.name = name;
	}
	public int getNum() {
		return num;
	}
	public String getName() {
		return name;
	}
}